In the XML folder an extensions.xml file is automatically created with the following code
<?xml version=”1.0” encoding=”UTF−8”?>
<extensions />
This file is used to make settings for the integration of your plugin within Insensa GIS.
We suggest to define the namespace for the xml file using the following code. This will allow autocompletion in IDEs.
<?xml version=”1.0” encoding=”UTF−8”?>
<extensions xmlns=”https://insensa.org/xsd/extensions”>
</extensions>
In the next step you have to define the extension type(s) you have developed.
As you can combine multiple function types within one plugin, you need different tags, one for each type you have included.
The following types are available:
For each function type add one name tag to the xml file as follows
<?xml version=”1.0” encoding=”UTF−8”?>
<extensions xmlns=”https://insensa.org/xsd/extensions”>
<inforeaders>
</inforeaders>
<options>
</options>
<connections>
</connections>
...
</extensions>
For each function type create an entry for each function being executed e.g. for inforeader:
<?xml version=”1.0” encoding=”UTF−8”?>
<extensions xmlns=”https://insensa.org/xsd/extensions”>
<inforeaders>
<inforeader id=”RInfoReaderExample”>
<service
type=”exec”
priority=”medium”
name=”R_InfoReaderExample”/>
<script
language=”R”
filename=”infoReaderExampleScript.R”/>
</inforeader>
</inforeaders>
<options>
</options>
<connections>
</connections>
...
</extensions>
where id should be a unique identifier that is later used in the user interface to access this function. Service type can be on of the following
Priority should be set to medium and name may be the same as the id but does not have to be unique. The following script tag defines the language of the plugin. At the moment R and Java are possible and filename is the filename of the script.
For Java Plugins, the package as well as the classname need to be defined as well.
It is possible to add help to the insensa UI and documentation of Insensa GIS authomatically. Add a help tag to the settings service tag as following:
<?xml version=”1.0” encoding=”UTF−8”?>
<extensions xmlns=”https://insensa.org/xsd/extensions”>
<inforeaders>
<inforeader id=”RInfoReaderExample”>
<service
type=”exec”
priority=”medium”
name=”R_InfoReaderExample”>
<script
language=”R”
filename=”infoReaderExampleScript.R”/>
</service>
<service
type=”settings”
priority=”medium”
name=”R_InfoReaderSettings”>
<script
filename=”R_InfoReaderSettings.R”
language=”R” />
<help
filename=”index.html”
id=”helpInfoReaderExample”
toc=”InfoReaderExampleTOC”/>−
</service>
</inforeader>
</inforeaders>
<options>
</options>
<connections>
</connections>
...
</extensions>